package edu.xaut.bookingsys.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;

import java.time.LocalDate;

/***
 *LogMessage
 * 用以记录老师接收或发送的消息,消息通常是触发，在排课冲突时，用于沟通
 *
 */
@Data
@TableName("LogBookingMessage")
public class LogBookingMessage {
    @TableId(value = "messageId", type = IdType.AUTO)
    private Long messageId;
    @TableField("fromTeacherId")
    private int fromTeacherId;
    @TableField("toTeacherId")
    private int toTeacherId;

    private String message; //消息内容
    @TableField("messageDate")
    private LocalDate messageDate;// 消息时间


    @TableField(exist = false)
    private InfoTeacher fromTeacher;
    @TableField(exist = false)
    private InfoTeacher toTeacher;
}
